package com.webside.points.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.webside.points.mapper.AdvertisingMapper;
import com.webside.points.model.AdvertisingEntity;
import com.webside.points.service.AdvertisingService;
@Service
public class AdvertisingServiceImpl implements AdvertisingService{
	
	@Autowired
	AdvertisingMapper advertisingMapper;

	@Override
	public List<AdvertisingEntity> findAll() {
		return advertisingMapper.findAll();
	}

	@Override
	public int insert(AdvertisingEntity advertisingEntity) {
		return advertisingMapper.insert(advertisingEntity);
	}

	@Override
	public int delete(int id) {
		return advertisingMapper.delete(id);
	}

	@Override
	public AdvertisingEntity findById(int id) {
		return advertisingMapper.findById(id);
	}

	@Override
	public AdvertisingEntity findByLocation(String location) {
		return advertisingMapper.findByLocation(location);
	}

	@Override
	public int update(AdvertisingEntity advertisingEntity) {
		return advertisingMapper.update(advertisingEntity);
	}

	@Override
	public int updateStatus(AdvertisingEntity advertisingEntity) {
		return advertisingMapper.updateStatus(advertisingEntity);
	}

}
